<?php
# autoHTML: the dynamic PHP5 library for fast website prototyping
# http://code.google.com/p/autohtml/
#
# Copyright (c) 2010, Shu Zong Chen
# http://freelanceDreams.com/
# All rights reserved. 
# 
# Redistribution and use in source and binary forms, with or without 
# modification, are permitted provided that the following conditions are met: 
# 
#  * Redistributions of source code must retain the above copyright notice, 
#    this list of conditions and the following disclaimer. 
#  * Redistributions in binary form must reproduce the above copyright 
#    notice, this list of conditions and the following disclaimer in the 
#    documentation and/or other materials provided with the distribution. 
#  * Neither the name of autoHTML nor the names of its contributors 
#    may be used to endorse or promote products derived from this software 
#    without specific prior written permission. 
# 
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS' 
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE 
# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 
# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 
# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
# POSSIBILITY OF SUCH DAMAGE.

########## starting the engine ###############################
# Start all your scripts by doing an include_once() with the autohtml_start.php file
# You can change some default behavior by uncommenting the following:
// $autohtml_dont_start_buffer = true; //Please call $autohtml->startBuffering() when you begin your body
// $autohtml_dont_instantiate = true; //Make your own manually with $autohtml = new AUTOHTML($autohtml_config);

include_once('../autohtml_start.php');
########## autoHTML engine started ##########################


########## configuring your page ############################
# Autohtml deals with your doctype, header and CSS/JS includes.
# If you have a site-wide .css or default template file, you might want to stick them
# in the autohtml_start.php file
$autohtml->setTitle('autoHTML - Hello World');
$autohtml->attachCSS('default.css');

########## starting output ##################################
# A hello world is as simple as just putting this text here.
?>
<div id="overlord">
	<div id="header">
	<h1>autoHTML</h1>
	</div>
	<div id="body">
		<h2>Hello World!</h2>
		<p>If you can read this, then your instance of autoHTML works!</p>
		<hr />
		<h2>Learning to use:</h2>
		<p>Autohtml comprises of many different modules. Each has its own purpose, and they can be used separately.</p>
		<dl>
			<dt><a href="/autohtml.html">autoHTML</a></dt>
			<dd>Binds all of these lesser packages together into a comprehensive suite.</dd>
			<dt><a href="/autoheader.html">autoHEADER</a></dt>
			<dd>Deals with HTML header goodness. Who remembers what to put in a doctype these days? Have this automatically manage your CSS and JS includes.</dd>
			<dt><a href="/autoasset.html">autoASSET</a></dt>
			<dd>Deals with asset (View in MVC) management. Store your templates and views anywhere you want: memory, on the filesystem, SQLite, other DBs!</dd>
			<dt><a href="/autotemplate.html">autoTEMPLATE</a></dt>
			<dd>Defunct. I'm hoping to have integration with other templating software before releasing this.</dd>
			<dt><a href="/autoquery.html">autoQUERY</a></dt>
			<dd>Defunct. There are other ORMs out there.</dd>
		</dl>
	</div>
</div>
<?php
# When all is said and done:
$autohtml->publish();